{include file="public:header" /}
<form id="info_form" action="{:url('Article/editDo')}" method="post" enctype="multipart/form-data">
<div class="pad_lr_10">
	<div class="col_tab">
		<ul class="J_tabs tab_but cu_li">
			<li class="current">基本信息</li>
			<li>SEO 设置</li>
		</ul>
		<div class="J_panes">
			<div class="content_list pad_10">
				<table width="100%" cellspacing="0" class="table_form">

                   	<tr>
						<th width="120">所属分类 :</th>
						<td><select class="J_cate_select mr10" data-pid="0" data-uri="{:url('ArticleCate/ajaxGetchilds')}" data-selected="{$selected_ids}"></select>
                			<input type="hidden" name="cate_id" id="J_cate_id" value="{$info.cate_id}" /></td>
					</tr>
					<tr>
						<th>所属城市 :</th>
						<td>
							<select class="J_city_select mr10" data-pid="0" data-uri="{:url('City/ajaxGetchilds')}" data-selected="{$info.city}"></select>
							<input type="hidden" name="city" id="J_city_id" value="" />
						</td>
					</tr>
		            <tr>
						<th>标题 :</th>
						<td>
		                    <input type="text" name="title" id="J_title" rel="title_color" class="input-text iColorPicker" size="60" value="{$info.title}">
						</td>
					</tr>
					<tr>
						<th>来源:</th>
						<td><input type="text" name="comefrom" id="comefrom" value="{$info.comefrom}" class="input-text" size="50" /></td>
					</tr>
					<tr>
						<th>标签:</th>
						<td><input type="text" name="tags" id="tags"  value="{$info.tags}" class="input-text" size="50" /><span>用','号分隔</span></td>
					</tr>
		            <tr>
						<th>缩略图:</th>
						<td>
							{notempty name="info['img']"}
								<img src="{$info.img}" width="100" height="100"/><br />
							{/notempty}
                        <input type="file" name="img" class="input-text"  style="width:200px;" /><span>图片尺寸：380*260</span>
                        </td>
		 			</tr>

					<tr>
						<th>状态 :</th>
		 				<td>
		                	<label><input type="radio" name="status" class="radio_style" value="1" {if condition="$info.status eq 1"}checked="checked"{/if}> 发布</label>&nbsp;&nbsp;
							<label><input type="radio" name="status" class="radio_style" value="0" {if condition="$info.status eq 0"}checked="checked"{/if}> 待审</label>
							<label><input type="radio" name="status" class="radio_style" value="2" {if condition="$info.status eq 2"}checked="checked"{/if}>退回</label>
							<label><input type="radio" name="status" class="radio_style" value="3" {if condition="$info.status eq 3"}checked="checked"{/if}>草稿</label>

						</td>
					</tr>
                    <tr>
                        <th>简介 :</th>
                        <td>
                            <textarea style="width:800px;height:80px;resize: none;"  name="description">{$info.description}</textarea>
                        </td>
                    </tr>
		            <tr>
		                <th>详细内容 :</th>
						<td><script id="info" name="info" type="text/plain">{$info.info}</script></td>
					</tr>
				</table>
			</div>
			<div class="content_list pad_10 hidden">
				<table width="100%" cellspacing="0" class="table_form">
					<tr>
						<th width="120">seo标题 :</th>
		 				<td><input type="text" name="seo_title" id="seo_title" class="input-text" size="60" value="{$info.seo_title}"></td>
					</tr>
					<tr>
						<th>seo关键词 :</th>
						<td><input type="text" name="seo_keys" id="seo_keys" class="input-text" size="60" value="{$info.seo_keys}"></td>
					</tr>
					<tr>
						<th>seo描述 :</th>
						<td><textarea name="seo_desc" id="seo_desc" cols="80" rows="8">{$info.seo_desc}</textarea></td>
					</tr>
				</table>
			</div>
			<input type="hidden" name="user_id" value="{$info.user_id}">

        </div>
		<div class="mt10"><input type="submit" value="提交" id="dosubmit" name="" class="btn btn_submit" style="margin:0 0 10px 100px;"><br /><br /><br /></div>
	</div>
</div>
<input type="hidden" name="id" id="id" value="{$info.id}" />
</form>
{include file="public:footer" /}
<script>
	$('.J_cate_select').cate_select();
	setTimeout(function(){$('.J_city_select').cate_select({level:1,field:'J_city_id',id:'J_city_select'})},1000);
	$(function() {
	$('ul.J_tabs').tabs('div.J_panes > div');
    $.formValidator.initConfig({formid:"info_form",autotip:true});
    $("#J_title").formValidator({onshow:'请填写标题',onfocus:'请填写标题'}).inputValidator({min:1,onerror:'请填写标题'}).defaultPassed();;
    $("#J_cate_id").formValidator({onshow:'请选择分类',onfocus:'请选择分类'}).regexValidator({regexp:"intege1",datatype:"enum",onerror:"请选择分类"}).defaultPassed();;

});
</script>
<script src="__PUBLIC__/js/plugins/jquery.tools.min.js"></script>
<script src="__PUBLIC__/js/ueditor/ueditor.config.js"></script>
<script src="__PUBLIC__/js/ueditor/ueditor.all.min.js"></script>
<script src="__PUBLIC__/js/ueditor/lang/zh-cn/zh-cn.js"></script>
<script type="text/javascript">
    window.UEDITOR_HOME_URL='__PUBLIC__/js/ueditor/';
    window.onload=function(){
        window.UEDITOR_CONFIG.initialFrameWidth=880;
        window.UEDITOR_CONFIG.initialFrameHeight=500;
        UE.getEditor('info');
      //  upmoreimg();
    }
</script>
<script src="__PUBLIC__/js/ueditor/uploadImg.js" charset="utf-8"></script>
</body>
</html>